import { Image } from "antd";
import logoPng from '@/assets/iamges/logo.png'
import { ImageProps } from "antd";
import './index.scss'

interface LogoProps extends ImageProps {
  margin?: string
  fontSize?: string
  showtext?: number
}

export default function Logo(props: LogoProps) {
  const {
    margin = '0',
    fontSize = '2rem',
    showtext = 1,
  } = props
  return (
    <div className="logo" style={{ margin: margin }}>
      <div className="logo-img">
        <Image src={logoPng} {...props} preview={false} ></Image>
        {showtext ? (<span style={{ fontSize: fontSize }} className="text">Panda</span>) : null}
      </div>
    </div>
  )
}